A magnetic type rotary encoder which utilizes a magneto-sensitive element such as a magneto-resistance effect (MR) element or a Hall element has been known as a device for detecting a rotation position of a rotor body to a fixed body. In the rotary encoder, induced voltage is generated in a wiring line, a circuit and the like due to a change of a magnetic field accompanied with rotation of a rotor body (magnet) and, when the signal component is superposed on an output signal of a magneto-sensitive element, the detection accuracy is deteriorated.
In Japanese Patent Laid-Open No. 2016-99164, a method is disclosed that an error caused by the induced voltage is corrected by utilizing that the induced voltage is superposed on an output signal in proportion to a rotational speed of a rotor body. In this method, a correction amount for cancelling an induced voltage at a specific rotational speed is previously stored and, based on the correction amount and a ratio between the specific rotational speed and a rotational speed in use, a correction value at the rotational speed in use is converted for cancelling the induced voltage. In this manner, a correction value which is increased in proportion to a rotational speed can be converted and calculated from a rotational speed in use and thus a rotation position of the rotor body can be detected with a high degree of accuracy.
However, in the correction method described in the above-mentioned Patent Literature, calculation accuracy of a rotational speed in use is not sufficient and thus calculation accuracy of a correction value for cancelling the induced voltage is not sufficient. As a result, it is difficult to realize a high degree of detection accuracy. Further, an error component which is superposed on an output signal accompanied with rotation of a rotor body cannot be removed and thus it is not sufficient to maintain a high degree of detection accuracy.